package com.ydt.controller;

import com.ydt.entity.UserRoattionimg;
import com.ydt.service.UserRoattionimgService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


import javax.annotation.Resource;
import java.util.List;

/**
 * (UserRoattionimg)表控制层
 *
 * @author makejava
 * @since 2020-12-24 15:27:28
 */
@RestController
@RequestMapping("userRoattionimg")
public class UserRoattionimgController {
    /**
     * 服务对象
     */
    @Resource
    private UserRoattionimgService userRoattionimgService;

    /**
     * 通过主键查询单条数据
     *
     * @param id 主键
     * @return 单条数据
     */
    @GetMapping("selectOne")
    public UserRoattionimg selectOne(Integer id) {
        return this.userRoattionimgService.queryById(id);
    }

    @GetMapping("all")
    public List<UserRoattionimg> all(){
        return this.userRoattionimgService.all();
    }
}